package com.jiaai.cloud.wx.service.impl;

import com.baomidou.mybatisplus.plugins.Page;
import com.jiaai.cloud.base.page.CustomPage;
import com.jiaai.cloud.wx.entity.TLifecycle;
import com.jiaai.cloud.wx.mapper.TLifecycleMapper;
import com.jiaai.cloud.wx.service.ITLifecycleService;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 生活圈信息表 服务实现类
 * </p>
 *
 * @author 佳爱网络科技
 * @since 2017-09-26
 */
@Service
public class TLifecycleServiceImpl extends ServiceImpl<TLifecycleMapper, TLifecycle> implements ITLifecycleService {

    @Autowired
    private TLifecycleMapper tLifecycleMapper;

    @Override
    public CustomPage<Map> queryForMyLifeCycleList(Integer userid, Page page) {
        page.setSearchCount(false);
        List<Map> list = tLifecycleMapper.queryForMyLifeCycleList(userid, page);
        page.setRecords(list);
        return new CustomPage<Map>(page);
    }
}
